class Express{
    constructor(){
        this.list = []
    
    }
    _all(path,fun,method){
        this.list.push({
            path, fun, method
        })
    }
    get(path,fun){
        this._all(path,fun,"GET")
    }
    post(path,fun){
        this._all(path,fun,"POST")
    }
    use(path,fun){
        this._all("*",fun,"ALL")
    }
}





function express(){
    return new Express()
}
let  app = express()
app.get("/log",()=>{console.log(1);})

app.get("/log2",()=>{console.log(12);})
app.get("/log3",()=>{console.log(123);})
app.post("/post",()=>{console.log(4);})
console.log(app.list);